import pymysql
from django.contrib.auth.decorators import login_required
from django.shortcuts import render
from FmyTest.models import versioncontrol



@login_required(login_url="/admin/login")
def index(request):
    # project_data = {}
    # results = versioncontrol.objects.filter(stats='s').values_list('soft_version', flat=True)
    # for i in list(results):
    #     project_data[i]=i
    # print(project_data)
    # return render(request, "index.html", {'project': project_data})
    return render(request, 'index.html')

def runoob(request):
    context = {}
    context['hello'] = 'hello world!'
    return render(request, 'runoob.html', context)

def teach(request):
    views_name = '教程'
    return render(request, 'runoob.html', {'name': views_name})

def forep(request):
    views_list = ['1', '2', '3', '4']
    return render(request, 'forep.html', {'views_list':views_list})

def mutliMenu(request):
    return render(request,'mutliMenu.html')


